﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace ZBJF.Warranty.Model.CommonObject.PinanAPIEntity
{
    public class InsuranceInfo
    {
        /// <summary>
        /// "partnerName【必填】":"合作伙伴用户名,平安提供",
        /// </summary>
        public string partnerName { get; set; }
        /// <summary>
        /// "departmentCode【必填】":"机构编码,平安提供",
        /// </summary>
        public string departmentCode { get; set; }
        /// <summary>
        /// 投保人信息-必填
        /// </summary>
        public ApplicantInfo applicantInfo { get; set; }
        public List<ProductInfo> productInfoList { get; set; }
    }
    public class ApplicantInfo
    {
        /// <summary>
        ///  "name【必填】":"名称",      
        /// </summary>
        public string name { get; set; }
        /// <summary>
        /// "birthday【非身份证时必填】":"出生年月 Date",
        /// </summary>
        public string birthday { get; set; }
        /// <summary>
        /// "sexCode【非身份证时必填】":"性别F,M ",  
        /// </summary>
        public string sexCode { get; set; }
        /// <summary>
        /// "certificateNo【必填】":"证件号码",
        /// </summary>
        public string certificateNo { get; set; }
        /// <summary>
        /// "certificateType【必填】":"证件类型,01:身份证、02：护照、03：军人证、04：港澳通行证，05：驾驶证、06：港澳回乡证或台胞证，07：临时身份证、99：其他"
        /// </summary>
        public string certificateType { get; set; }
        /// <summary>
        /// "address【选填】":"地址",
        /// </summary>
        public string address { get; set; }
        /// <summary>
        /// "postcode【选填】":"邮政编码",
        /// </summary>
        public string postcode { get; set; }
        /// <summary>
        /// "email【选填】":"E-mail", 
        /// </summary>
        public string email { get; set; }
        /// <summary>
        /// "homeTelephone【选填-和手机号码选一】":"家庭电话",
        /// </summary>
        public string homeTelephone { get; set; }
        /// <summary>
        ///  "mobileTelephone【选填，和家庭电话选一】":"手机号码", 
        /// </summary>
        public string mobileTelephone { get; set; }
        /// <summary>
        ///  "personnelType【选填 只支持个人默认是1】":"个团标志[1个人，0团体] "
        /// </summary>
        public string personnelType { get; set; }
    }

    public class ProductInfo
    {
        /// <summary>
        /// baseInfo【必填】"
        /// </summary>
        public ProductBaseInfo baseInfo { get; set; }
        /// <summary>
        /// extendInfo【选填-扩展信息】"
        /// </summary>
        public ProductExtendInfo extendInfo { get; set; }
        /// <summary>
        /// insurantInfoList【财产险-被保人列表-必填，】
        /// </summary>
        public List<ProductInsuranceInfo> insurantInfoList { get; set; }
        /// <summary>
        /// "specialPromiseList【选填-特约信息】":
        /// </summary>
        public List<ProductSpecialPromise> specialPromiseList { get; set; }
        /// <summary>
        ///  "riskGroupInfoList【必填-标的信息】"
        /// </summary>
        public List<ProductRiskGroupInfo> riskGroupInfoList { get; set; }
    }

    public class ProductBaseInfo
    {
        /// <summary>
        /// "transactionNo【必填,长度不要超过50】": "交易号(合作伙伴订单号，用于幂等性控制) String",
        /// </summary>
        public string transactionNo { get; set; }
        /// <summary>
        /// "totalActualPremium【必填】": "实交保费 Double",
        /// </summary>
        public string totalActualPremium { get; set; }
        /// <summary>
        /// "productCode【必填：平安业务提供】": "产品编码,通过某一险种定义出来的产品的编码 String",
        /// </summary>
        public string productCode { get; set; }
        /// <summary>
        /// "insuranceBeginDate【必填】": "保险起期 Date yyyy-MM-dd 24h:mm:ss",
        /// </summary>
        public string insuranceBeginDate { get; set; }
        /// <summary>
        /// "insuranceEndDate【必填】": "保险止期 Date yyyy-MM-dd 24h:mm:ss",
        /// </summary>
        public string insuranceEndDate { get; set; }
        /// <summary>
        /// "coinsuranceMark【选填】": "共保标志 0：非共保 1：共保 String",
        /// </summary>
        public string coinsuranceMark { get; set; }
        /// <summary>
        /// "businessType【选填，默认个人】": "业务类型/个团属性：1-个人，2-团体 String"
        /// </summary>
        public string businessType { get; set; }

    }

    public class ProductExtendInfo
    {
        /// <summary>
        /// "isSendInvoice【必填】": "是否发送电子发票   0不发送 1发送短信 2发送邮件 3短信邮件都发送 String",
        /// </summary>
        public string isSendInvoice { get; set; }
        /// <summary>
        /// "invokeMobilePhone【选填】": "发送电子发票短信的手机号码 String",
        /// </summary>
        public string invokeMobilePhone { get; set; }
        /// <summary>
        /// "invokeEmail【选填】": "发送电子发票邮件的邮箱 String",
        /// </summary>
        public string invokeEmail { get; set; }
        /// <summary>
        /// "taxPayerNO【选填】": "发票纳税人编号String"
        /// </summary>
        public string taxPayerNO { get; set; }
    }

    public class ProductInsuranceInfo
    {
        /// <summary>
        /// "name【必填】": "名称 ",     
        /// </summary>
        public string name { get; set; }
        /// <summary>
        /// "birthday【必填】": "出生年月 Date yyyy-MM-dd",
        /// </summary>
        public string birthday { get; set; }
        /// <summary>
        /// "age": "年龄 Short",
        /// </summary>
        public string age { get; set; }
        /// <summary>
        /// "sexCode":"性别F,M ",  
        /// </summary>
        public string sexCode { get; set; }
        /// <summary>
        ///"certificateNo【必填】": "证件号码 String",
        /// </summary>
        public string certificateNo { get; set; }
        /// <summary>
        /// "certificateType【必填】": " 证件类型,01:身份证、02：护照、03：军人证、04：港澳通行证，05：驾驶证、06：港澳回乡证或台胞证，07：临时身份证、99：其他",
        /// </summary>
        public string certificateType { get; set; }
        /// <summary>
        /// "address【选填】": "地址 String",
        /// </summary>
        public string address { get; set; }
        /// <summary>
        ///"postcode【选填】": "邮政编码 String",
        /// </summary>
        public string postcode { get; set; }
        /// <summary>
        /// "email【选填】": "E-mail String",
        /// </summary>
        public string email { get; set; }
        /// <summary>
        /// "homeTelephone【选填,家庭电话和手机号码选一】": "家庭电话 String",
        /// </summary>
        public string homeTelephone { get; set; }
        /// <summary>
        /// "mobileTelephone【选填,家庭电话和手机号码选一】": "手机号码 String",
        /// </summary>
        public string mobileTelephone { get; set; }
        /// <summary>
        /// "personnelType【选填】": "个团标志[1个人，0团体] String"
        /// </summary>
        public string personnelType { get; set; }
    }

    public class ProductSpecialPromise
    {
        /// <summary>
        ///  "promiseCode【必填】": "特约编号 String",
        /// </summary>
        public string promiseCode { get; set; }
        /// <summary>
        /// "promiseDesc【必填】": "特约描述 String",
        /// </summary>
        public string promiseDesc { get; set; }
        /// <summary>
        /// "promiseType【必填】": "Y为可改特约N为固定特约X为可选特约B为底部特约 String"
        /// </summary>
        public string promiseType { get; set; }
    }

    public class ProductRiskGroupInfo
    {
        /// <summary>
        /// "applyNum【必填，默认是1】":"投保份数 Double",
        /// </summary>
        public double applyNum { get; set; }
        /// <summary>
        /// "productPackageType【必填：非标产品可选填】":"产品套餐编码",
        /// </summary>
        public double productPackageType { get; set; }
        /// <summary>
        /// "combinedProductCode【选填，产品组合[MP02000057,MP02000072]必填，由平安提供】】":"组合产产品中被关联的产品编码"
        /// </summary>
        public double combinedProductCode { get; set; }
        /// <summary>
        /// 【必填-个财】
        /// </summary>
        public List<ProductRiskPropertyInfo> riskPropertyInfoList { get; set; }
    }

    public class ProductRiskPropertyInfo
    {
        /// <summary>
        /// "riskPropertyMap【必填，财产险自定义信息，不同产品不同信息】":{"标的信息字段":"见数据字典：产品标的信息"},
        /// </summary>
        public object riskPropertyMap { get; set; }
    }
}
